﻿using System;
using SharpSqlAnalyzer.nodes;

namespace SharpSqlAnalyzer.stmt.mssql
{
	// Token: 0x0200016F RID: 367
	public class TMssqlDropDbObject : TCustomSqlStatement
	{
		// Token: 0x06000CBB RID: 3259 RVA: 0x00307CC9 File Offset: 0x00305EC9
		public TMssqlDropDbObject(EDbVendor dbvendor) : base(dbvendor)
		{
			this.sqlstatementtype = ESqlStatementType.sstmssqldropdbobject;
		}

		// Token: 0x06000CBC RID: 3260 RVA: 0x00307CDD File Offset: 0x00305EDD
		internal override void buildsql()
		{
		}

		// Token: 0x06000CBD RID: 3261 RVA: 0x00307CDF File Offset: 0x00305EDF
		internal override void clear()
		{
		}

		// Token: 0x06000CBE RID: 3262 RVA: 0x00307CE1 File Offset: 0x00305EE1
		internal override string getasprettytext()
		{
			return "";
		}

		// Token: 0x06000CBF RID: 3263 RVA: 0x00307CE8 File Offset: 0x00305EE8
		internal virtual void iterate(TVisitorAbs pvisitor)
		{
		}

		// Token: 0x1700025B RID: 603
		// (get) Token: 0x06000CC0 RID: 3264 RVA: 0x00307CEA File Offset: 0x00305EEA
		// (set) Token: 0x06000CC1 RID: 3265 RVA: 0x00307CF2 File Offset: 0x00305EF2
		public virtual TObjectNameList ObjectNameList
		{
			get
			{
				return this.objectNameList;
			}
			set
			{
				this.objectNameList = value;
			}
		}

		// Token: 0x1700025C RID: 604
		// (get) Token: 0x06000CC2 RID: 3266 RVA: 0x00307CFB File Offset: 0x00305EFB
		// (set) Token: 0x06000CC3 RID: 3267 RVA: 0x00307D03 File Offset: 0x00305F03
		public virtual EDbObjectType DbObjectType
		{
			get
			{
				return this.dbObjectType;
			}
			set
			{
				this.dbObjectType = value;
			}
		}

		// Token: 0x06000CC4 RID: 3268 RVA: 0x00307D0C File Offset: 0x00305F0C
		public override int doParseStatement(TCustomSqlStatement psql)
		{
			if (this.rootNode == null)
			{
				return -1;
			}
			base.doParseStatement(psql);
			if (this.rootNode is TDropDbObjectSqlNode)
			{
				TDropDbObjectSqlNode tdropDbObjectSqlNode = (TDropDbObjectSqlNode)this.rootNode;
				this.objectNameList = tdropDbObjectSqlNode.ObjectNameList;
				if (this.objectNameList != null)
				{
					for (int i = 0; i < this.objectNameList.size(); i++)
					{
						this.objectNameList.getObjectName(0).ObjectType = 3;
					}
				}
				this.dbObjectType = tdropDbObjectSqlNode.DbObjectType;
			}
			return 0;
		}

		// Token: 0x06000CC5 RID: 3269 RVA: 0x00307D8D File Offset: 0x00305F8D
		public override void accept(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x06000CC6 RID: 3270 RVA: 0x00307D9D File Offset: 0x00305F9D
		public override void acceptChildren(TParseTreeVisitor v)
		{
			v.preVisit(this);
			v.postVisit(this);
		}

		// Token: 0x040012F3 RID: 4851
		private TObjectNameList objectNameList;

		// Token: 0x040012F4 RID: 4852
		private EDbObjectType dbObjectType;
	}
}
